package Algorithm;

/**
 * @Author zengxianlong
 * @Date 2021/11/19 14:24
 * @Version 1.0
 */
public class Fishing {

   public static void main(String[] args) {
      int fish=1;
      while (true){
         int total=fish;
         Boolean enough=true;
         System.out.println("fish:"+fish);
         for (int i=0;i<5;i++){
            if ((total-1)%5==0){
               total=(total-1)/5*4;
               System.out.println("total:"+total);
            }else {
               enough=false;
               break;
            }
         }
         System.out.println("enough:"+enough);
         if (enough){
            System.out.println("总共有:"+fish+"条鱼");
            break;
         }
         fish+=1;
      }

   }

}
